3.82 \(\int \frac{1+x^2}{1+x^4} \, dx\)

Optimal. Leaf size=35 \[ \frac{\tan ^{-1}\left (\sqrt{2} x+1\right )}{\sqrt{2}}-\frac{\tan ^{-1}\left (1-\sqrt{2} x\right )}{\sqrt{2}} \]

[Out]

-(ArcTan[1 - Sqrt[2]*x]/Sqrt[2]) + ArcTan[1 + Sqrt[2]*x]/Sqrt[2]

_______________________________________________________________________________________

Rubi [A]  time = 0.0421558, antiderivative size = 35, normalized size of antiderivative = 1., number of steps used = 5, number of rules used = 3, integrand size = 13, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.231 \[ \frac{\tan ^{-1}\left (\sqrt{2} x+1\right )}{\sqrt{2}}-\frac{\tan ^{-1}\left (1-\sqrt{2} x\right )}{\sqrt{2}} \]

Antiderivative was successfully verified.

[In]  Int[(1 + x^2)/(1 + x^4),x]

[Out]

-(ArcTan[1 - Sqrt[2]*x]/Sqrt[2]) + ArcTan[1 + Sqrt[2]*x]/Sqrt[2]

_______________________________________________________________________________________

Rubi in Sympy [A]  time = 4.60352, size = 32, normalized size = 0.91 \[ \frac{\sqrt{2} \operatorname{atan}{\left (\sqrt{2} x - 1 \right )}}{2} + \frac{\sqrt{2} \operatorname{atan}{\left (\sqrt{2} x + 1 \right )}}{2} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  rubi_integrate((x**2+1)/(x**4+1),x)

[Out]

sqrt(2)*atan(sqrt(2)*x - 1)/2 + sqrt(2)*atan(sqrt(2)*x + 1)/2

_______________________________________________________________________________________

Mathematica [A]  time = 0.0205835, size = 30, normalized size = 0.86 \[ \frac{\tan ^{-1}\left (\sqrt{2} x+1\right )-\tan ^{-1}\left (1-\sqrt{2} x\right )}{\sqrt{2}} \]

Antiderivative was successfully verified.

[In]  Integrate[(1 + x^2)/(1 + x^4),x]

[Out]

(-ArcTan[1 - Sqrt[2]*x] + ArcTan[1 + Sqrt[2]*x])/Sqrt[2]

_______________________________________________________________________________________

Maple [B]  time = 0.006, size = 88, normalized size = 2.5 \[{\frac{\arctan \left ( \sqrt{2}x-1 \right ) \sqrt{2}}{2}}+{\frac{\sqrt{2}}{8}\ln \left ({\frac{1+{x}^{2}+\sqrt{2}x}{1+{x}^{2}-\sqrt{2}x}} \right ) }+{\frac{\arctan \left ( 1+\sqrt{2}x \right ) \sqrt{2}}{2}}+{\frac{\sqrt{2}}{8}\ln \left ({\frac{1+{x}^{2}-\sqrt{2}x}{1+{x}^{2}+\sqrt{2}x}} \right ) } \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  int((x^2+1)/(x^4+1),x)

[Out]

1/2*arctan(2^(1/2)*x-1)*2^(1/2)+1/8*2^(1/2)*ln((1+x^2+2^(1/2)*x)/(1+x^2-2^(1/2)*
x))+1/2*arctan(1+2^(1/2)*x)*2^(1/2)+1/8*2^(1/2)*ln((1+x^2-2^(1/2)*x)/(1+x^2+2^(1
/2)*x))

_______________________________________________________________________________________

Maxima [A]  time = 0.819567, size = 53, normalized size = 1.51 \[ \frac{1}{2} \, \sqrt{2} \arctan \left (\frac{1}{2} \, \sqrt{2}{\left (2 \, x + \sqrt{2}\right )}\right ) + \frac{1}{2} \, \sqrt{2} \arctan \left (\frac{1}{2} \, \sqrt{2}{\left (2 \, x - \sqrt{2}\right )}\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((x^2 + 1)/(x^4 + 1),x, algorithm="maxima")

[Out]

1/2*sqrt(2)*arctan(1/2*sqrt(2)*(2*x + sqrt(2))) + 1/2*sqrt(2)*arctan(1/2*sqrt(2)
*(2*x - sqrt(2)))

_______________________________________________________________________________________

Fricas [A]  time = 0.274277, size = 32, normalized size = 0.91 \[ \frac{1}{2} \, \sqrt{2}{\left (\arctan \left (\frac{1}{2} \, \sqrt{2}{\left (x^{3} + x\right )}\right ) + \arctan \left (\frac{1}{2} \, \sqrt{2} x\right )\right )} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((x^2 + 1)/(x^4 + 1),x, algorithm="fricas")

[Out]

1/2*sqrt(2)*(arctan(1/2*sqrt(2)*(x^3 + x)) + arctan(1/2*sqrt(2)*x))

_______________________________________________________________________________________

Sympy [A]  time = 0.213157, size = 39, normalized size = 1.11 \[ \frac{\sqrt{2} \left (2 \operatorname{atan}{\left (\frac{\sqrt{2} x}{2} \right )} + 2 \operatorname{atan}{\left (\frac{\sqrt{2} x^{3}}{2} + \frac{\sqrt{2} x}{2} \right )}\right )}{4} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((x**2+1)/(x**4+1),x)

[Out]

sqrt(2)*(2*atan(sqrt(2)*x/2) + 2*atan(sqrt(2)*x**3/2 + sqrt(2)*x/2))/4

_______________________________________________________________________________________

GIAC/XCAS [A]  time = 0.26763, size = 53, normalized size = 1.51 \[ \frac{1}{2} \, \sqrt{2} \arctan \left (\frac{1}{2} \, \sqrt{2}{\left (2 \, x + \sqrt{2}\right )}\right ) + \frac{1}{2} \, \sqrt{2} \arctan \left (\frac{1}{2} \, \sqrt{2}{\left (2 \, x - \sqrt{2}\right )}\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((x^2 + 1)/(x^4 + 1),x, algorithm="giac")

[Out]

1/2*sqrt(2)*arctan(1/2*sqrt(2)*(2*x + sqrt(2))) + 1/2*sqrt(2)*arctan(1/2*sqrt(2)
*(2*x - sqrt(2)))